package cn.jiyun.service.impl;

import cn.jiyun.entity.Message;
import cn.jiyun.mapper.User2Mapper;
import cn.jiyun.model.User;
import cn.jiyun.service.User2Service;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class User2ServiceImpl extends ServiceImpl<User2Mapper, User> implements User2Service {
    @Override
    public Page findPage1(Integer pageNum, Integer pageSize, User user) {
        Page<User> userPage = new Page<>(pageNum, pageSize);
        List<User> list = baseMapper.findPage(userPage,user);
        return userPage.setRecords(list);
    }
}
